﻿using Newtonsoft.Json;

namespace VueShopApi.Dtos
{
    public class CategoryDto
    {
        /// <summary>
        /// 分类唯一ID
        /// </summary>
        [JsonProperty("cat_id")]
        public int CatId { get; set; }

        /// <summary>
        /// 是否删除 1为删除
        /// </summary>
        [JsonProperty("cat_deleted")]
        public bool CatDeleted { get; set; }

        [JsonProperty("cat_icon")]
        public string CatIcon { get; set; }

        /// <summary>
        /// 分类层级 0: 顶级 1:二级 2:三级
        /// </summary>
        [JsonProperty("cat_level")]
        public int CatLevel { get; set; }

        /// <summary>
        /// 分类名称
        /// </summary>
        [JsonProperty("cat_name")]
        public string CatName { get; set; }

        /// <summary>
        /// 分类父ID
        /// </summary>
        [JsonProperty("cat_pid")]
        public int CatPid { get; set; }

        [JsonProperty("cat_src")]
        public string CatSrc { get; set; }

        public List<CategoryDto> Children { get; set; }
    }
}
